summaryrefslogtreecommitdiff
path: root/app/[lng]/evcp/(evcp)
diff options
context:
space:
mode:
Diffstat (limited to 'app/[lng]/evcp/(evcp)')
-rw-r--r--app/[lng]/evcp/(evcp)/(master-data)/basic-contract-template/[id]/page.tsx16
-rw-r--r--app/[lng]/evcp/(evcp)/(procurement)/rfq-last/[id]/compare/page.tsx8
-rw-r--r--app/[lng]/evcp/(evcp)/(system)/approval/line/page.tsx5
-rw-r--r--app/[lng]/evcp/(evcp)/(system)/approval/template/page.tsx5
-rw-r--r--app/[lng]/evcp/(evcp)/(system)/email-log/page.tsx2
-rw-r--r--app/[lng]/evcp/(evcp)/(system)/email-template/page.tsx3
-rw-r--r--app/[lng]/evcp/(evcp)/(system)/qna/[id]/page.tsx5
7 files changed, 23 insertions, 21 deletions
diff --git a/app/[lng]/evcp/(evcp)/(master-data)/basic-contract-template/[id]/page.tsx b/app/[lng]/evcp/(evcp)/(master-data)/basic-contract-template/[id]/page.tsx
index bcf3e1f4..65d8a56f 100644
--- a/app/[lng]/evcp/(evcp)/(master-data)/basic-contract-template/[id]/page.tsx
+++ b/app/[lng]/evcp/(evcp)/(master-data)/basic-contract-template/[id]/page.tsx
@@ -13,15 +13,14 @@ import { getBasicContractTemplateByIdService, refreshTemplatePage } from "@/lib/
import { TemplateEditorWrapper } from "@/lib/basic-contract/template/template-editor-wrapper"
interface BasicContractTemplateDetailPageProps {
- params: {
+ params: Promise<{
id: string
- }
+ }>
}
// 메타데이터 생성
-export async function generateMetadata({
- params
-}: BasicContractTemplateDetailPageProps): Promise<Metadata> {
+export async function generateMetadata(props: BasicContractTemplateDetailPageProps): Promise<Metadata> {
+ const params = await props.params;
const template = await getBasicContractTemplateByIdService(params.id);
if (!template) {
@@ -37,9 +36,8 @@ export async function generateMetadata({
};
}
-export default async function BasicContractTemplateDetailPage({
- params
-}: BasicContractTemplateDetailPageProps) {
+export default async function BasicContractTemplateDetailPage(props: BasicContractTemplateDetailPageProps) {
+ const params = await props.params;
const template = await getBasicContractTemplateByIdService(params.id);
if (!template) {
@@ -49,7 +47,7 @@ export default async function BasicContractTemplateDetailPage({
// 페이지 새로고침 서버 액션
const handleRefresh = async () => {
"use server"
- await refreshTemplatePage(params.id);
+ await refreshTemplatePage(template.id.toString());
};
return (
diff --git a/app/[lng]/evcp/(evcp)/(procurement)/rfq-last/[id]/compare/page.tsx b/app/[lng]/evcp/(evcp)/(procurement)/rfq-last/[id]/compare/page.tsx
index 461a0863..792640b9 100644
--- a/app/[lng]/evcp/(evcp)/(procurement)/rfq-last/[id]/compare/page.tsx
+++ b/app/[lng]/evcp/(evcp)/(procurement)/rfq-last/[id]/compare/page.tsx
@@ -17,13 +17,15 @@ export default async function ComparePage({
params,
searchParams
}: ComparePageProps) {
- const rfqId = parseInt(params.id);
+ const resolvedParams = await params;
+ const resolvedSearchParams = await searchParams;
+ const rfqId = parseInt(resolvedParams.id);
console.log(rfqId,"rfqId")
- console.log(searchParams.vendors,"searchParams.vendors")
+ console.log(resolvedSearchParams.vendors,"searchParams.vendors")
// URL에서 벤더 ID들 파싱
- const vendorIds = searchParams.vendors
+ const vendorIds = resolvedSearchParams.vendors
?.split(',')
.map(id => parseInt(id))
.filter(id => !isNaN(id)) || [];
diff --git a/app/[lng]/evcp/(evcp)/(system)/approval/line/page.tsx b/app/[lng]/evcp/(evcp)/(system)/approval/line/page.tsx
index 38b43680..2e96b434 100644
--- a/app/[lng]/evcp/(evcp)/(system)/approval/line/page.tsx
+++ b/app/[lng]/evcp/(evcp)/(system)/approval/line/page.tsx
@@ -15,10 +15,11 @@ export const metadata: Metadata = {
};
interface PageProps {
- searchParams: SearchParams;
+ searchParams: Promise<SearchParams>;
}
-export default async function ApprovalLinePage({ searchParams }: PageProps) {
+export default async function ApprovalLinePage(props: PageProps) {
+ const searchParams = await props.searchParams;
const search = SearchParamsApprovalLineCache.parse(searchParams);
// getValidFilters 반환값이 undefined 인 경우 폴백
const validFilters = getValidFilters(search.filters) ?? [];
diff --git a/app/[lng]/evcp/(evcp)/(system)/approval/template/page.tsx b/app/[lng]/evcp/(evcp)/(system)/approval/template/page.tsx
index f475099c..c5834b05 100644
--- a/app/[lng]/evcp/(evcp)/(system)/approval/template/page.tsx
+++ b/app/[lng]/evcp/(evcp)/(system)/approval/template/page.tsx
@@ -15,10 +15,11 @@ export const metadata: Metadata = {
};
interface PageProps {
- searchParams: SearchParams;
+ searchParams: Promise<SearchParams>;
}
-export default async function ApprovalTemplatePage({ searchParams }: PageProps) {
+export default async function ApprovalTemplatePage(props: PageProps) {
+ const searchParams = await props.searchParams;
const search = SearchParamsApprovalTemplateCache.parse(searchParams);
// getValidFilters 반환값이 undefined 인 경우 폴백
const validFilters = getValidFilters(search.filters) ?? [];
diff --git a/app/[lng]/evcp/(evcp)/(system)/email-log/page.tsx b/app/[lng]/evcp/(evcp)/(system)/email-log/page.tsx
index b73674e4..41001cc7 100644
--- a/app/[lng]/evcp/(evcp)/(system)/email-log/page.tsx
+++ b/app/[lng]/evcp/(evcp)/(system)/email-log/page.tsx
@@ -14,7 +14,7 @@ export const metadata: Metadata = {
}
interface EmailLogPageProps {
- searchParams: SearchParams
+ searchParams: Promise<SearchParams>
}
export default async function EmailLogPage(props: EmailLogPageProps) {
diff --git a/app/[lng]/evcp/(evcp)/(system)/email-template/page.tsx b/app/[lng]/evcp/(evcp)/(system)/email-template/page.tsx
index 7f4de341..16c75dab 100644
--- a/app/[lng]/evcp/(evcp)/(system)/email-template/page.tsx
+++ b/app/[lng]/evcp/(evcp)/(system)/email-template/page.tsx
@@ -22,11 +22,10 @@ export const metadata: Metadata = {
}
interface TemplatePageProps {
- searchParams: SearchParams
+ searchParams: Promise<SearchParams>
}
export default async function TemplatePage(props: TemplatePageProps) {
-
const searchParams = await props.searchParams
const search = SearchParamsEmailTemplateCache.parse(searchParams)
diff --git a/app/[lng]/evcp/(evcp)/(system)/qna/[id]/page.tsx b/app/[lng]/evcp/(evcp)/(system)/qna/[id]/page.tsx
index 93b948c6..ebd4cbb3 100644
--- a/app/[lng]/evcp/(evcp)/(system)/qna/[id]/page.tsx
+++ b/app/[lng]/evcp/(evcp)/(system)/qna/[id]/page.tsx
@@ -2,8 +2,9 @@ import { getQnaById } from "@/lib/qna/service";
import QnaDetail from "@/lib/qna/table/qna-detail";
import { notFound } from "next/navigation";
-export default async function QnaDetailPage({ params }: { params: { id: string } }) {
- const question = await getQnaById(params.id);
+export default async function QnaDetailPage({ params }: { params: Promise<{ id: string }> }) {
+ const resolvedParams = await params;
+ const question = await getQnaById(resolvedParams.id);
if (!question) {
notFound();